@import "../../const";
@import "../../../../shared/color";

.zr-profile {
	height: @profile-height;
	//background-color: @header-logo-bg-color;
	color: @icon-color;
	padding: 10px;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	border-bottom: 1px solid darken(@header-logo-bg-color, 3%);
	position: relative;
	overflow: hidden;
	
	& > div {
		z-index: 2;
		//解决safari下z-index失效问题
		position: relative;
	}
	
	.profile-background {
		filter: blur(40px);
		position: absolute;
		top: 0px;
		bottom: 0px;
		left: 0px;
		right: 0px;
		z-index: 0;
		
		img {
			position: absolute;
			top: -10px;
			bottom: -10px;
			left: -10px;
			right: -10px;
			width: 100%;
			height: 100%;
		}
	}
	
	.profile-background-mask {
		position: absolute;
		top: 0;
		bottom: 0;
		left: 0;
		right: 0;
		z-index: 1;
		background-color: rgba(0, 0, 0, 1);
	}
	
	&.collapsed {
		height: @header-height;
		border-bottom: none;
		
		.logo-image {
			width: @avatar-size / 2;
			height: @avatar-size / 2;
			overflow: hidden;
			
			img {
				width: @avatar-size / 2;
				height: @avatar-size / 2;
			}
		}
		
		.profile-background {
			filter: blur(20px);
		}
	}
	
	.logo-image {
		width: @avatar-size;
		height: @avatar-size;
		border-radius: 50%;
		display: flex;
		justify-content: center;
		align-items: center;
		background-color: rgba(0, 0, 0, 0.06);
		overflow: hidden;
		
		img {
			width: @avatar-size;
			height: @avatar-size;
		}
	}
	
	.logo-icon {
		font-size: 36px;
	}
	
	.profile-user-info {
		width: 160px;
		white-space: nowrap;
		overflow: hidden;
		font-size: @avatar-font-size;
		text-align: center;
		font-weight: bold;
		color: @text-color-normal;
		margin-top: 10px;
		
		&.details {
			font-size: 12px;
			margin-top: 4px;
			
			& .user-role {
				color: #8e8e8e;
				font-size: 14px;
			}
		}
		
		&.expended {
			transition-delay: .2s;
			transition-duration: .4s;
			transition-property: width;
		}
	}
	
}